package com.ssy.lingxi.platform.manage.api.feign.inner;

import com.ssy.lingxi.common.response.Wrapper;
import com.ssy.lingxi.platform.manage.api.hystrix.inner.AreaControllerFeignFallback;
import com.ssy.lingxi.platform.manage.api.model.vo.area.AreaVO;
import io.swagger.annotations.ApiOperation;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

/**
 * @menu 省市区三级联动管理
 * @author wrc
 * @version 2.0.0
 * @date 2020/7/20
 */
@FeignClient(value = "platform-manage-service", fallback = AreaControllerFeignFallback.class)
public interface AreaControllerFeign {

    @ApiOperation(value = "根据省编码获取所有市编码")
    @GetMapping("/manage/area/findCityCodeByProvinceCode")
    Wrapper<List<String>> findCityCodeByProvinceCode(@RequestParam("provinceCodes") List<String> provinceCodes);

    @ApiOperation(value = "查询省市区列表")
    @GetMapping("/manage/area/list")
    Wrapper<List<AreaVO>> areaList();
}
